import requests from "../requests/requests";

// 获取数据库中students 的数据
export const reqstudentlist = ()=> requests({url:"/students",method:'GET'})

// 向数据库中添加数据
export const sendmsgs = (name:String,
    age:any,
    sex:String,
    date:any,
    address:String
    )=>requests({
    url:"/addstudents",
    method:"GET",
    params:{
        name,
        age,
        sex,
        date,
        address
    }
})

// 删除数据
export const reqdetemsg = (multipleSelection:any)=>requests({
    url:   '/delestudent',
    method:"GET",
    params:{
        multipleSelection
    }
})

//搜索
export const  reqsearmsg = (content:any) => requests({url:'/searstudent'
    ,method:'GET',
    params:{
        content
    }
})